checkSelfPermission
Checks whether your app has a given permission and whether the app op that corresponds to this permission is allowed.
Return
The permission check result which is either PERMISSION_GRANTED or PERMISSION_DENIED or PERMISSION_DENIED_APP_OP.
Parameters
context
Context for accessing resources.
permission
The permission to check.